package com.flyone.fuxiao.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.flyone.fuxiao.model.entity.PostHistory;
import com.flyone.fuxiao.model.vo.DrawHistoryRecordVO;
import com.flyone.fuxiao.model.vo.PostHistoryVO;

import javax.servlet.http.HttpServletRequest;
import java.util.List;

/**
* @author luoyifei
* @description 针对表【post_history(历史记录表)】的数据库操作Service
* @createDate 2024-03-28 21:12:49
*/
public interface PostHistoryService extends IService<PostHistory> {

    /**
     * 获取用户所有历史记录
     * @param request 请求
     * @return 用户所有历史记录
     */
    List<PostHistoryVO> getAllHistory(HttpServletRequest request);

    /**
     * 获取该token所有历史记录
     * @param token token
     * @param request 请求
     * @return 用户所有历史记录
     */
    List<DrawHistoryRecordVO> getHistoryRecordByToken(String token, HttpServletRequest request);

    /**
     * 删除该token所有历史记录
     * @param token token
     * @param request 请求
     * @return 删除结果
     */
    String deleteHistoryRecordByToken(String token, HttpServletRequest request);
}
